import axios from 'axios';
import {hideLoading, showError, showLoading} from './uiPrompt';

export const fetchAllCities = () => {
    showLoading();
    return new Promise((resolve, reject) => {
        axios.get('/city.json').then(res => {
            resolve(res.data);
            hideLoading();
        }).catch(err => {
            hideLoading();
            showError('获取城市信息失败');
            reject(err);
        });
    });
// 拜拜啦 睡觉去了
};